package com.esp.soccertutor.fbreader.fbreader;

import com.esp.soccertutor.zlibrary.core.options.ZLStringOption;
import com.esp.soccertutor.zlibrary.text.view.style.ZLTextStyleCollection;

public class ChangeFontFamilyAction extends FBAction{

	private String fontName;
	public ChangeFontFamilyAction(FBReaderApp fbreader,String fname) {
		super(fbreader);
		fontName=fname;
	}

	
	@Override
	public void run() {
		ZLStringOption option =ZLTextStyleCollection.Instance().getBaseStyle().FontFamilyOption;
		option.setValue(fontName);
		Reader.clearTextCaches();
		Reader.getViewWidget().repaint();
	}

}
